import time
from selenium.webdriver.common.by import By
from selenium import webdriver
from lianxi.lianxi2.Page import Page
import unittest,pytest
class TestCase(unittest.TestCase):
    def setUp(self) ->None:
        self.driver=webdriver.Edge()
        self.driver.maximize_window()
    def tearDown(self) ->None:
        time.sleep(2)
        self.driver.quit()
    def test_A3mall_01(self):
        po=Page(self.driver)
        po.luoji_login()
if __name__ == '__main__':
    unittest.main()
@pytest.fixture
def driver():
    driver=webdriver.Edge()
    driver.maximize_window()
    yield driver
    time.sleep(2)
    driver.quit()
def test_01_A3mall(driver):
    po=Page(driver)
    po.luoji_login()
if __name__ == '__main__':
    pytest.main()